<?php
/**
 * 文章实体
 * Create on 2016-05-26 16:06:20
 * Create by yuebin
*/
namespace haibao\cms\business\control\pc\entity;

class ArticleEntity extends BaseEntity{
	
	public $level = 3;
	public $bigLevel = 7;
	public $offset = 0;
	public $limit = 5;
	public $isProImage = 1;
	public $isConditionTag = false;
	public $isPrimaryTag = true;
	public $isReturnTag = true;
	public $isImageColl = true;
	public $source = '';
	public $proImageLevel = null;
	public $infoIds = null;
	public $orderByNew = true;//按照最新排序 
	public $orderType = 'desc';
	public $orderByClick = null;//按照点击量排序
	public $orderByCommentClick = null;//按评论量排序
	public $dateType;//时间段类型 1一周 2一个月 3半个月 4 3天
	public $isPage = false;
	public $isDate = false;
	public $currentPage = 1;
	public $isLeftJoinTag = false;
	public $tagIds = null;
	public $isParentTag = false;
	public $isOnlyReturnPrimaryTag = true;
	
	public function __construct(){
		parent::__construct();
	}
	
	public function setLevel($level){
		$this->level = (int)$level;
	}
	public function getLevel(){
		return $this->level;
	}

	public function setBigLevel($bigLevel){
		$this->bigLevel = (int)$bigLevel;
	}
	public function getBigLevel(){
		return $this->bigLevel;
	}
	
	public function setOffset($offset){
	    $this->offset = $offset;
	}
	public function getOffset(){
	    return $this->offset;
	}

	public function setLimit($limit){
		$this->limit = (int)$limit;
	}
	public function getLimit(){
		return $this->limit;
	}

	public function setIsProImage($isProImage){
		$this->isProImage = $isProImage;
	}
	public function getIsProImage(){
		return $this->isProImage;
	}

	public function setIsConditionTag($isConditionTag){
		$this->isConditionTag = $isConditionTag;
	}
	public function getIsConditionTag(){
		return $this->isConditionTag;
	}

	public function setIsPrimaryTag($isPrimaryTag){
		$this->isPrimaryTag = $isPrimaryTag;
	}
	public function getIsPrimaryTag(){
		return $this->isPrimaryTag;
	}

	public function setIsReturnTag($isReturnTag){
		$this->isReturnTag = $isReturnTag;
	}
	public function getIsReturnTag(){
		return $this->isReturnTag;
	}

	public function setIsImageColl($isImageColl){
		$this->isImageColl = $isImageColl;
	}
	public function getIsImageColl(){
		return $this->isImageColl;
	}

	public function setSource($source){
		$this->source = $source;
	}
	public function getSource(){
		return $this->source;
	}
	
	public function setTagIds($tagIds){
	    $this->tagIds = $tagIds;
	}
	
	public function getTagIds(){
	    return $this->tagIds;
	}

	public function setProImageLevel($proImageLevel){
		$this->proImageLevel = $proImageLevel;
	}
	public function getProImageLevel(){
		return $this->proImageLevel;
	}

	public function setIsPage($isPage){
		$this->isPage = $isPage;
	}
	public function getIsPage(){
		return $this->isPage;
	}
	public function setIsDate($isDate,$dateType){
	    if($isDate){
	        $this->dateType = $dateType;
	    }
		$this->isDate = $isDate;
	}
	public function getIsDate(){
		return $this->isDate;
	}
	public function setCurrentPage($currentPage){
		$this->currentPage = $currentPage;
	}
	public function getCurrentPage(){
		return $this->currentPage;
	}
	public function setIsLeftJoinTag($isLeftJoinTag){
		$this->isLeftJoinTag = $isLeftJoinTag;
	}
	public function getIsLeftJoinTag(){
		return $this->isLeftJoinTag;
	}
	public function setIsParentTag($isParentTag){
		$this->isParentTag = $isParentTag;
	}
	public function getIsParentTag(){
		return $this->isParentTag;
	}
	
	public function setIsOnlyReturnPrimaryTag($isOnlyReturnPrimaryTag){
		$this->isOnlyReturnPrimaryTag = $isOnlyReturnPrimaryTag;
	}
	public function getIsOnlyReturnPrimaryTag(){
		return $this->isOnlyReturnPrimaryTag;
	}
	
	public function setOrderByNew($isOrderByNew,$orderType = \haibao\cms\business\control\pc\action\ArticleAction::SORT_DESC){//是否按时间排序  升序还是降序
	    if($isOrderByNew){
	        $this->orderType = $orderType;
	    }
	    $this->orderByNew = $isOrderByNew;
	}
	public function getOrderByNew(){
	    return $this->orderByNew;
	}
	
	public function setOrderByCommentClick($orderByCommentClick){
	    $this->orderByCommentClick = $orderByCommentClick;
	}
	
	public function getOrderByCommentClick(){
	    return $this->orderByCommentClick;
	}
	
	public function setOrderByClick($orderByClick){
	    $this->orderByClick = $orderByClick;
	}
	
	public function getOrderByClick(){
	    return $this->orderByClick;
	}
	
	public function setNotInId($infoIds){
	    $this->infoIds = $infoIds;
	}
	
	public function getNotInId(){
	    return $this->infoIds;
	}
	
}